package com.example.demo.controller;

import org.springframework.beans.factory.annotation.Value;
import org.springframework.web.bind.annotation.*;

@RestController
public class HelloWorldController {

    @Value("${spring.application.name}")
    private String appName;

    @GetMapping("/hello")
    public String helloWorld() {
        return "Hello " + appName;
    }
}
